package com.tidy.seed.admin.system.vo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.tidy.seed.util.TreeUtils;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Builder;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.ArrayList;
import java.util.List;

/**
 * FindAllTreeVo VO
 * 描述：
 *
 * @author 59717
 * @date 2025-08-05
 */
@Data
@Builder
@ApiModel(description = "值对象")
public class FindAllTreeVO implements Serializable, TreeUtils.ITreeNode<FindAllTreeVO> {
    // 常用字段示例 - 根据实际业务删除或添加

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "菜单名称", notes = "字段名：menuName")
    private String menuName;

    @ApiModelProperty(value = "菜单编号", notes = "字段名：menuKey")
    private String menuKey;

    @ApiModelProperty(value = "菜单图标", notes = "字段名：menuIcon")
    private String menuIcon;

    @ApiModelProperty(value = "路由路径", notes = "字段名：path")
    private String path;

    @ApiModelProperty(value = "前端路由组件地址", notes = "字段名：componentPath")
    private String componentPath;

    @ApiModelProperty(value = "菜单类型 1-菜单 2按钮 3跳转外链", notes = "字段名：menuType")
    private Integer menuType;

    @ApiModelProperty(value = "字典排序", notes = "字段名：sort")
    private Integer sort;

    @ApiModelProperty(value = "备注", notes = "字段名：remark")
    private String remark;

    @ApiModelProperty(value = "父亲id", notes = "字段名：parentId")
    private Integer parentId;

    private static final long serialVersionUID = 1L;
    @ApiModelProperty(value = "创建时间", notes = "字段名：createAt")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime createAt;

    @ApiModelProperty(value = "更新时间", notes = "字段名：updateAt")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime updateAt;
    @ApiModelProperty(value = "子节点", example = "[]")
    private List<FindAllTreeVO> children = new ArrayList<>();
    private Integer value;
    private String label;

}
    